package pwd.allen.fastdfs.config;

import com.github.tobato.fastdfs.FdfsClientConfig;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.EnableMBeanExport;
import org.springframework.context.annotation.Import;
import org.springframework.jmx.support.RegistrationPolicy;

/**
 * 引入FdfsClientConfig实现自动配置
 *
 * @author licyaae
 * @date 2021/06/02
 */
@Configuration
@Import(FdfsClientConfig.class) // todo 好像不用加也行吧，springboot的自动装配
/**
 * 处理Jmx重复注册bean的问题，好像也可以通过属性配置：spring.jmx.enabled=false
 * 不加可能会报错：Unable to register MBean [FdfsConnectionPool
 */
@EnableMBeanExport(registration = RegistrationPolicy.IGNORE_EXISTING)
public class DfsConfig {
}
